import request from '@/utils/request'

export function fetchList(query) {
  return request({
    url: '/pian/list',
    method: 'get',
    params: query
  })
}

export function update(query) {
  return request({
    url: '/pian/edit',
    method: 'post',
    data: query
  })
}
export function buy(query) {
  return request({
    url: '/pian/buy',
    method: 'post',
    data: query
  })
}

export function deleteById(query) {
  return request({
    url: '/pian/delete',
    method: 'post',
    params: query
  })
}

export function add(query) {
  return request({
    url: '/pian/add',
    method: 'post',
    params: query
  })
}
